package com.baibei.model;

import android.os.Parcel;
import android.os.Parcelable;

import java.io.Serializable;

/**
 * Created by shenminjie on 2017/10/30.
 * mail:shenminjie@100bei.com
 */

public class InoutFundParam extends BaseParam implements Serializable, Parcelable {

    private double amount;
    private String url;
    private double balance;
    private String fundPassword;
    private PayModeInfo payModeInfo;

    @Override
    public String toString() {
        return "InoutFundParam{" +
                "amount=" + amount +
                ", url='" + url + '\'' +
                ", balance=" + balance +
                ", fundPassword='" + fundPassword + '\'' +
                ", payModeInfo=" + payModeInfo +
                '}' + super.toString();
    }



    public double getAmount() {
        return amount;
    }

    public void setAmount(double amount) {
        this.amount = amount;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public double getBalance() {
        return balance;
    }

    public void setBalance(double balance) {
        this.balance = balance;
    }

    public String getFundPassword() {
        return fundPassword;
    }

    public void setFundPassword(String fundPassword) {
        this.fundPassword = fundPassword;
    }

    public PayModeInfo getPayModeInfo() {
        return payModeInfo;
    }

    public void setPayModeInfo(PayModeInfo payModeInfo) {
        this.payModeInfo = payModeInfo;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        super.writeToParcel(dest, flags);
        dest.writeDouble(this.amount);
        dest.writeString(this.url);
        dest.writeDouble(this.balance);
        dest.writeString(this.fundPassword);
        dest.writeParcelable(this.payModeInfo, flags);
    }

    public InoutFundParam() {
    }

    protected InoutFundParam(Parcel in) {
        super(in);
        this.amount = in.readDouble();
        this.url = in.readString();
        this.balance = in.readDouble();
        this.fundPassword = in.readString();
        this.payModeInfo = in.readParcelable(PayModeInfo.class.getClassLoader());
    }

    public static final Creator<InoutFundParam> CREATOR = new Creator<InoutFundParam>() {
        @Override
        public InoutFundParam createFromParcel(Parcel source) {
            return new InoutFundParam(source);
        }

        @Override
        public InoutFundParam[] newArray(int size) {
            return new InoutFundParam[size];
        }
    };
}

